package com.jt.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jt.pojo.Item;
import com.jt.vo.EasyUITable;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface ItemMapper extends BaseMapper<Item>{
    @Select("select count(id) from tb_item")
    Long countItemByPage();
//    手动
    @Select("select * from tb_item order by updated desc limit #{start},#{rows} ")
    List<Item> findItemByPage(@Param("start") int start,@Param("rows") int rows);


    void deleteItem(@Param("ids") Long... ids);

    void updateStatus(Long[] ids,Integer status);
    /*@Update("update tb_item set ")
    void updateItemById(Item item);*/
}
